CREATE TABLE [dbo].[TRTGAS_USUA]
(
[CO_EMPR] [dbo].[TD_VC_002] NOT NULL,
[CO_TIPO_GAST] [dbo].[TD_VC_003] NOT NULL,
[CO_USUA] [dbo].[TD_VC_008] NOT NULL,
[CO_USUA_CREA] [dbo].[TD_VC_008_USUA] NOT NULL CONSTRAINT [DF__TRTGAS_US__CO_US__7CAF6937] DEFAULT (suser_sname()),
[FE_USUA_CREA] [dbo].[TD_DT_001_SIST] NOT NULL CONSTRAINT [DF__TRTGAS_US__FE_US__7DA38D70] DEFAULT (getdate()),
[CO_USUA_MODI] [dbo].[TD_VC_008_USUA] NOT NULL CONSTRAINT [DF__TRTGAS_US__CO_US__7E97B1A9] DEFAULT (suser_sname()),
[FE_USUA_MODI] [dbo].[TD_DT_001_SIST] NOT NULL CONSTRAINT [DF__TRTGAS_US__FE_US__7F8BD5E2] DEFAULT (getdate())
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[TRTGAS_USUA] ADD CONSTRAINT [PK__TRTGAS_U__33AEAAA11CF21B97] PRIMARY KEY CLUSTERED  ([CO_EMPR], [CO_TIPO_GAST], [CO_USUA]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[TRTGAS_USUA] ADD CONSTRAINT [FK__TRTGAS_USUA__23BF14B7] FOREIGN KEY ([CO_EMPR], [CO_TIPO_GAST]) REFERENCES [dbo].[TTTIPO_GAST] ([CO_EMPR], [CO_TIPO_GAST])
GO
